package entity;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.JoinColumns;
import javax.persistence.OneToOne;

@Entity
public class Service implements Serializable{
	private static final long serialVersionUID = 1L;
	@Column(name="SERVICENAME", length=50)
	private String serviceName;
	@Id
	@Column(name="SERVICEURI", length=200)
	private String serviceURI;
	@OneToOne
	@JoinColumns(
	{
		@JoinColumn(name="USERID"),
		@JoinColumn(name="USERNAME")
	}
	)
	private UserCheck usercheck;
	
	public Service() {
	}
	
	public Service(String serviceName, String serviceURI){
		this.serviceName = serviceName;
		this.serviceURI = serviceURI;
	}
	
	public String getServiceName() {
		return serviceName;
	}
	public void setServiceName(String serviceName) {
		this.serviceName = serviceName;
	}
	public String getServiceURI() {
		return serviceURI;
	}
	public void setServiceURI(String serviceURI) {
		this.serviceURI = serviceURI;
	}
	public UserCheck getUsercheck() {
		return usercheck;
	}
	public void setUsercheck(UserCheck usercheck) {
		this.usercheck = usercheck;
	}
}
